package cn.ycxy.lbl.pojo.posts.domain;

import com.baomidou.mybatisplus.annotation.*;

import java.time.LocalDateTime;
import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 二手交易分类表
 * </p>
 *
 * @author BaoL
 * @since 2023-03-19
 */
@Data
@ApiModel(value="LblCsDealClassify对象", description="二手交易分类表")
public class LblCsDealClassify implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "自增主键")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "分类名称")
    private String classifyName;

    @ApiModelProperty(value = "父级类别id，如果无父级，则为0")
    private Integer parentId;

    @ApiModelProperty(value = "深度，最顶级类别的深度为1，次级为2，以此类推")
    private Integer depth;

    @ApiModelProperty(value = "自定义排序序号")
    private Integer sort;

    /**
     * 逻辑删除
     *  value : 未删除
     *  delval : 已删除
     *  逻辑删除注解, 在每次查询时, 都将会带上该逻辑删除字段进行查询
     */
    @TableLogic(value = "1", delval = "0")
    @ApiModelProperty(value = "是否启用，1=启用，0=未启用")
    private Integer enable;

    @ApiModelProperty(value = "数据创建时间")
    @TableField(fill = FieldFill.INSERT)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    private LocalDateTime createTime;

    @ApiModelProperty(value = "数据最后更新时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
    private LocalDateTime updateTime;


}
